# !/usr/bin/env python
# -*- coding: utf-8 -*-

# 调整日期自适应-autofmt_xdate
if __name__ == '__main__':
    import numpy as np
    import pandas as pd
    import matplotlib.pyplot as plt
    x = pd.date_range('2020/01/01', periods=30)
    y = np.arange(0, 30, 1)
    plt.plot(x, y)
    plt.gcf().autofmt_xdate()
    plt.show()
